<?php
	$tid = $_POST['tid'];
	if(!$tid){
		exit('tid is miss !');
	}
	require "../autoload.php";
	$p = new MyPdo();
	$sql = "select * from translate_not_join where tid = ?";
	$arr = array($tid);
	$res = $p->dql($sql,$arr);
	if($res){
		$sql = "delete from translate_not_join where tid = ?";
		$info = '已参与全部！';
	}else{
		$sql = "insert into translate_not_join values(null,?)";
		$info = '已不参与全部！';
	}
	$res = $p->dml($sql,$arr);
	if($res){
		$dirs[] = '../Runtime/Cache_long/all';
		//$dirs[] = '../Runtime/CacheLefts/'.md5('all');
		$dirs[] = '../Runtime/Cache_long/indexButtonGroup_tabType';
		foreach($dirs as $v){
			if(is_file($v)){
				unlink($v);
			}
		}
		echo $info;
	}


